package com.uyii.springbootelasticsearch.demos.web;

import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

@Data
@Document(indexName = "product")
public class Product {

    @Id
    private String id;

    private String name;

    @Field(type = FieldType.Double)
    private Double price;
}